module.exports = {
  base: '/blog/',
  dest: 'docs',
  title: 'aboatedu-技术博客',
  description: '执着于更高的技术追求',
  head: [
    ['link', {
      rel: 'icon',
      href: 'favicon.ico'
    }],
    ['meta', {
      name: 'theme-color',
      content: '#3eaf7c'
    }],
  ],
  themeConfig: {
    sidebarDepth: 3,
    navBar: true,
    lastUpdated: '上次更新',
    nav: [{
      text: '团队建设',
      items: [{
        text: '建设规则',
        link: '/rule/team'
      },
      {
        text: '职级与OKR',
        link: '/rule/rank'
      },
      {
        text: '统一配置文件',
        link: '/rule/config'
      },
      {
        text: '资产管理',
        link: '/rule/money'
      },
      {
        text: '2021年终总结',
        link: '/conclusion/2021/liutianbao'
      }
      ]
    },
    {
      text: '教程',
      items: [
        {
          text: 'markdown语法',
          link: '/share/md'
        },
        {
          text: '环境配置',
          link: '/share/env'
        },
        {
          text: 'git cz提交配置',
          link: '/share/git-cz'
        },
        {
          text: 'JS基础',
          link: '/js/1'
        },
        {
          text: 'SEO解决方案',
          link: '/share/seo'
        },
        {
          text: '为什么要用nuxt',
          link: '/nuxt/1'
        },
        { 
          text: '.env配置',
          link: '/share/envCfg'
        }
      ]
    },
    {
      text: '技术积累',
      items: [{
        text: '常用方法',
        link: '/accumulate/1'
      },
      {
        text: '缓存问题',
        link: '/accumulate/cache'
      },
      {
        text: '问题整理',
        link: '/javaScript/array1'
      },
      {
        text: 'yarn',
        link: '/yarn/1'
      },
      {
        text: '输入url到页面呈现',
        link: '/openUrl/1'
      },
      {
        text: '手把手教你深浅拷贝',
        link: '/copy/1'
      },
      {
        text: '初步了解Vue3.0中diff算法的优化',
        link: '/diff/1'
      },
      {
        text: '简易任务队列',
        link: '/task/1'
      },
      {
        text: '图标选择器',
        link: '/iconPicker/1'
      },
      {
        text: 'vue3.2',
        link: '/vue3.2/1'
      },
      {
        text: 'css选择器',
        link: '/css/1'
      },
      {
        text: 'a==1&&a==2&&a==12',
        link: '/objectValueOf/1'
      },
      {
        text: 'css',
        link: '/css1/is()'
      },
      {
        text: 'git与svn',
        link: '/git/1'
      },
      {
        text: '数据类型4种判断',
        link: '/typeJudge/1'
      },
      {
        text: '常用的正则表达式',
        link: '/regular/1'
      },
      {
        text: '强制结束forEach',
        link: '/typeJudge/2'
      }
      ]
    },
    {
      text: '客户端专区',
      items: [{
        text: 'iOS规范',
        link: '/app/iOS-1'
      },
      {
        text: 'iOS正则表达式',
        link: '/app/iOS-2'
      },
      {
        text: 'Swift好用的便捷技巧',
        link: '/app/iOS-3'
      },
      {
        text: 'TCP:IP',
        link: '/app/tcpip'
      },
      {
        text: 'iOS UIKit框架',
        link: '/app/iOS UIKit框架'
      },
      {
        text: 'iOS中WebKit框架应用与解析',
        link: '/app/iOS中WebKit框架应用与解析'
      },
      {
        text: 'Android-popwindow',
        link: '/app/android-popwindow'
      },
      {
        text: 'Android-Kotlin-扩展函数',
        link: '/app/android-kotlin'
      },
      {
        text: 'Android-handler',
        link: '/app/android-handler'
      },
      {
        text: 'Android-Kotlin-协程',
        link: '/app/android-kotlin协程'
      },
      {
        text: 'android-constraintlayout',
        link: '/app/android-constraintlayout'
      }
      ]
    },
    {
      text: '常用网址',
      link: '/url/fe'
    }
    ],
    sidebar: {
      '/accumulate/': genSidebarConfig('常用方法', ['1', '2', '3', '4', '5']),
      '/js/': genSidebarConfig('JS基础', ['1', '2', '3', '4', '5', '6', '7', '8', '9']),
      '/javaScript/': genSidebarConfig('问题整理', ['array1', '1', '2', '3']),
      '/yarn/': genSidebarConfig('yarn', ['1', '2', '3']),
      '/iconPicker/': genSidebarConfig('iconPicker', ['1', '2', '3', '4']),
      '/css1/': genSidebarConfig('iconPicker', ['is()']),
      '/conclusion/': genSidebarConfig('2021年终总结', ['2021/liutianbao', '2021/renshupei', '2021/cuiyifan', '2021/linzhen', '2021/zengguang', '2021/tianmichai', '2021/sunyuerong', '2021/zhangjunfang', '2021/ludapeng', '2021/shizhiyong', '2021/xvjianguo', '2021/wuwenye', '2021/yangkun'])
    }
  },
  plugins: [
    [
      '@vuepress/last-updated',
      {
        dateOptions: {
          hour12: false
        }
      }
    ]
  ]
}

function genSidebarConfig(title, children) {
  return [{
    title,
    children
  }]
}